import java.util.Scanner;

/**
 * 字符串分隔
 */
public class HJ4 {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        String str = sc.nextLine();
        int len = str.length();
        int i = 0;
        while (len > 0) {
            StringBuffer sb = new StringBuffer();
            if (len <= 8) {
                int j = 8 - len;
                sb.append(str.substring(8 * i));
                for (int k = 0; k < j; k++) {
                    sb.append("0");
                }
                System.out.printf(sb.toString());
                break;
            } else {
                sb.append(str, 8 * i, 8 * i + 8);
                System.out.println(sb);
                i++;
                len -= 8;
            }
        }
    }
}
